import React, { ReactNode, useState } from "react";
import CreateUser from "./Page/CreateUser";
import { CreateUserReq } from "./model/user";
import { Button, Flex, Menu } from "antd";
import ProgDialog from "./component/ProgDialog";
import ProgDialogGroup from "./component/ProgDialogGroup";

interface ItemType {
  key: string,
  label: string,
}

const items: ItemType[] = [
  {
    key: 'reg',
    label: '注册',
  }
];

function p(i: number) {
  switch (i) {
    case 0: return CreateUser;
    case 1: return Button;
    default: return Flex;
  }
}

function App() {

  return (
    <>
      <Flex vertical>
        <Menu mode="horizontal" items={items} />
        <CreateUser span={6} offset={1} />
      </Flex>
      <ProgDialogGroup/>
    </>
  );
}

export default App;
